package com.atguigu.exam;

/**
 * @author xbd
 * @create 2021-05-26 18:23
 */
public class MonthTest {
    public static void main(String[] args) {
        Month day = Month.APRIL;
        System.out.println(day);
        System.out.println("******************");

        Month[] days = Month.values();
        for (int i = 0; i < days.length; i++) {
            System.out.println(days[i]);
        }
    }
}

enum Month{
    JANUARY("01"),
    FEBRUARY("02"),
    MARCH("03"),
    APRIL("04"),
    MAY("05"),
    JUNE("06"),
    JULY("07"),
    AUGUST("08"),
    SEPTEMBER("09"),
    OCTOBER("10"),
    NOVEMBER("11"),
    DECEMBER("12");

    private final String months;

    private Month(String months) {
        this.months = months;
    }
}